<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/extras/spring-security">
<head th:replace="common :: common_header(~{::title},~{::link})">
<meta charset="UTF-8">
<title th:text="${borrowInfo.name}">${borrow.name}</title>
<link rel="stylesheet" href="" th:href="@{/css/details.css}">
</head>
<body>
	<div th:replace="~{index :: top}"></div>
	<div class="container">
		<div class="row">
			<div class="col-md-8">
				<div class="panel panel-default">
					<div class="panel-body">
						<div th:text="${'个人消费贷 - '+borrowInfo.name}">个人消费贷 -</div>
						<p th:text="${borrowInfo.repaymentMethod}"></p>
						<div class="project-rates-wrap">
							<div class="rate">
								<strong th:text="${borrowInfo.investRate}">8.5</strong><span>%</span>
								<label>约定利率（年华）</label>
							</div>
							<div class="rate">
								<strong th:text="${borrowInfo.period}">6</strong><span>个月</span>
								<label>项目期限</label>
							</div>
							<div class="rate">
								<strong th:text="${borrowInfo.totalMoney / 10000}">2</strong><span>万</span>
								<label>借款金额</label>
							</div>
							<div class="clearfix"></div>
						</div>
						<div>
							<div class="progress">
								<div class="progress-bar" style="width: 60%;">
									<span class="sr-only">60%</span>
								</div>
							</div>
							<div class="project-progress-text">
								已经完成投标 20,000.00 元 ，每万元预期收益<span>251.72</span> 元
							</div>
						</div>

						<div>
							<ul class="nav nav-tabs" role="tablist">
								<li role="presentation" class="active" >
									<a href="#projectDetails" data-toggle="tab">项目详情</a>
								</li>
								<li role="presentation">
									<a href="#repaymentPlan" data-toggle="tab">还款计划</a>
								</li>
								<li role="presentation">
									<a href="#projectCourse" data-toggle="tab">项目历程</a>
								</li>
								<li role="presentation" >
									<a href="#tenderList" data-toggle="tab">投资列表</a>
								</li>
							</ul>

							<div class="tab-content">
								<div role="tabpanel" class="tab-pane active projectInfo" id="projectDetails">
									<h3>融资信息</h3>
									<hr>
									<div class="row">
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>项目名称</dt>
												<dd th:text="${borrowInfo.name}">dsadsa</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>项目简介</dt>
												<dd>本项目的个人融资介绍</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>融资方</dt>
												<dd th:text="${#strings.substring(borrowInfo.borrower.username,0,2) + '*****'}">dsadsa**dsada</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>所在地</dt>
												<dd>湖南</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>年化利率</dt>
												<dd th:text="${#numbers.formatPercent(borrowInfo.investRate / 100,1,0)}">8.5%</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>自动投标额度</dt>
												<dd>0.60万元</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>借款金额</dt>
												<dd th:text="${borrowInfo.totalMoney / 10000 + '万元'}">2万元</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>本期融资金额</dt>
												<dd>2万元</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>借款期限</dt>
												<dd>6个月</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>本次授信额度</dt>
												<dd>2万元</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>起息日</dt>
												<dd>投资后次日起息</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>计划还款日期</dt>
												<dd>2018-6-12</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>还款来源</dt>
												<dd>个人收入</dd>
											</dl>
										</div>
										<div class="col-md-6">
											<dl class="dl-horizontal">
												<dt>投标截止时间</dt>
												<dd>2017-12-14 00：00：00</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>担保措施</dt>
												<dd>个人信用</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>还款方式</dt>
												<dd>等额本息。</dd>
											</dl>
										</div>
									</div>
									
									<h3>借款人基本信息</h3>
									<hr>
									<div class="row">
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>本体性质</dt>
												<dd>自然人</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>姓名</dt>
												<dd th:text="${#strings.substring(borrowInfo.borrower.realName,0,1) + '****'}"></dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>性别</dt>
												<dd>女</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>年龄</dt>
												<dd>32岁</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>学历</dt>
												<dd>大学专科和专科学校</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>婚姻状态</dt>
												<dd>已婚</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>证件号码</dt>
												<dd th:text="${#strings.substring(borrowInfo.borrower.idNumber,0,4) + '*************' + #strings.substring(borrowInfo.borrower.idNumber,16,18)}">430******21</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>平均历史逾期次数</dt>
												<dd>0次</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>平台历史逾期金额</dt>
												<dd>0.00元</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>平台当前逾期金额</dt>
												<dd>0.00元</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>收入范围</dt>
												<dd>8000元-15000元</dd>
											</dl>
										</div>
										<div class="col-md-12">
											<dl class="dl-horizontal">
												<dt>工作单位性质</dt>
												<dd>私企</dd>
											</dl>
										</div>
									</div>
								</div>
								
								<div id="tenderList" class="tab-pane" role="tabpanel">
									<table class="table">
										<thead>
											<tr>
												<th>时间</th>
												<th>用户</th>
												<th>投资金额(元)</th>
											</tr>
										</thead>
										<tbody>
											<tr>
												<td>2017-12-12 12：12：12</td>
												<td>ws**14</td>
												<td>309.04</td>
											</tr>
										</tbody>
									</table>
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
			<div class="col-md-4">
				<div class="panel panel-default">
					<div class="panel-body">
						<p>可投金额<span th:text="${borrowInfo.totalMoney - borrowInfo.investMoney}">6,602.45</span>元</p>
						<div>
							<div sec:authorize="!isAuthenticated()">
								<div class="join-tip">您尚未登录，请先登录</div>
								<div class="button-wrap">
									<a href="/user/index" th:href="@{/borrow/tender(borrowId=${borrowInfo.id})}" class="btn btn-primary btn-block">请先登录</a>
								</div>
							</div>
							<div sec:authorize="isAuthenticated()">
								<form>
								<div class="form-group">
									<div class="input-group">
										<div class="input-group-addon">￥</div>
										<input type="text" class="form-control" placeholder="请输入投资金额">	
									</div>
								</div>
								<div class="row form-group">
									<div class="col-md-6">可用余额<span>0.00</span>元</div>
									<div class="col-md-6 text-right"><a href="#" th:href="@{/user/recharge}">去充值</a></div>
								</div>
								<div class="form-group">
									<input type="submit" class="btn btn-primary btn-block">
								</div>
								</form>
							</div>
							<div class="text-center">
								<small class="" style="r: #999;font-size: 85%">剩余时间1天8小时20分</small>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
		<div th:fragment="copyright">@ 2017 黄文杰</div>
	</div>
	
</body>
</html>